<template>
	<view class="store-list-page">
		<view class="top-bar">

			<u-dropdown ref="uDropdown" @open="onDropdownOpen">
				<u-dropdown-item isOnlyClick title="新北区新北区新北区新北区新北区"></u-dropdown-item>
				<u-dropdown-item title="默认排序" v-model="value1" :options="options1"></u-dropdown-item>
				<u-dropdown-item title="筛选">
					<view class="condition-box">
						<view class="condition-list">
							<view class="item" :class="item.value === value2 ? 'active' : ''" v-for="(item, index) in options2" :key="index">{{item.label}}</view>
						</view>
						<view class="btn-box">
							<view class="btn reset-btn">重置</view>
							<view class="btn confirm-btn">确定</view>
						</view>
					</view>
				</u-dropdown-item>
			</u-dropdown>

		</view>


		<view class="position-bar">
			<view class="left">
				<u-icon name="map" color="#525252" size="36"></u-icon>
				<text class="text">常州市新北区常州市新北区常州市新北区常州市新北区常州市新北区常州市新北区</text>
			</view>
			<view class="right">
				<u-icon name="reload" color="#1E8AF4" size="30"></u-icon>
				<text class="text">刷新</text>
			</view>
		</view>

		<view class="main">






			<view class="item">
				<view class="top-box">
					<view class="image-box">
						<image src="../../static/images/huishou_index_banner.jpg" mode="" class="img"></image>
					</view>
					<view class="info-box">
						<view class="top">
							<view class="tag tag-1">公司直营点</view>
							<u-icon name="arrow-right" color="#707070" size="30"></u-icon>
						</view>
						<view class="title">常州市武进高新区武南路588号新城南路花海二期</view>
					</view>
				</view>
				<view class="footer-box">
					<view class="value-box">
						<text class="label">订单总数</text>
						<text class="no">668</text>
					</view>
					<view class="distance">距您1.47km</view>
				</view>
			</view>
			<view class="item">
				<view class="top-box">
					<view class="image-box">
						<image src="../../static/images/huishou_index_banner.jpg" mode="" class="img"></image>
					</view>
					<view class="info-box">
						<view class="top">
							<view class="tag tag-1">公司直营点</view>
							<u-icon name="arrow-right" color="#707070" size="30"></u-icon>
						</view>
						<view class="title">常州市武进高新区武南路588号新城南路花海二期</view>
					</view>
				</view>
				<view class="footer-box">
					<view class="value-box">
						<text class="label">订单总数</text>
						<text class="no">668</text>
					</view>
					<view class="distance">距您1.47km</view>
				</view>
			</view>

			<loading-footer :status="status"></loading-footer>
		</view>
	</view>
</template>

<script>
	import {
		loadingType
	} from '@/utils/type'

	const app = getApp()
	export default {

		data() {
			return {
				value: '',
				status: loadingType.LOADING,
				value1: 1,
				options1: [{
						label: '默认排序',
						value: 1,
					},
					{
						label: '附近优先',
						value: 2,
					},
					{
						label: '销量优先',
						value: 3,
					}
				],

				value2: 1,
				options2: [{
						label: '全部',
						value: 1,
					},
					{
						label: '直营门店',
						value: 2,
					},
					{
						label: '旗舰门店',
						value: 3,
					},
					{
						label: '服务网点',
						value: 4,
					},
				],
			}
		},
		async onLoad(options) {

		},
		async onShow() {

		},

		methods: {
			onDropdownOpen(index) {
				console.log("index", index)
			},
			onSubmit() {
				if (this.value) {

				}
			},

			onClickRadioText(item, index) {
				this.value = item.name
			},

			bindPickerChange(e) {

			},

			async getBestListFun() {
				let {
					page,
					goodsList,
					status
				} = this
				const data = await loadingFun(getBestList, page, goodsList, status)
				if (!data) return
				this.page = data.page
				this.goodsList = data.dataList
				this.status = data.status
			},



		},
	}
</script>

<style lang="scss">
	@import "index.scss";
</style>